Notes/Domino 6 and 7 Forum

Notes/Domino 6 and 7 Forum





how to parse a HTML Mail Body?
~John Lopfanakonyli 01/28/2004 04:04 PM
Domino Designer 6.0.3 Linux - SuSE


Hi,

I try to write an Agent to parse the content of a HTML Mail.
I write the following Code, but it dose not work :-?

session.setConvertMIME(false);
MIMEEntity mime = docMail.getMIMEEntity();
Stream stream = session.createStream();
mime.getContentAsText(stream);
stream.close();
String sBody=stream.readText();
if (sBody.indexOf("some text")>-1) {
//... my code goes here...
}
sBody=sBody.toLowerCase();

But the String sBody always is emty?
Any idea?

Thanks for help

Ralph Soika

Go back